<html>
<head>
	<title>Excersise 4</title>
	<link href="styles/js-console.css" rel="stylesheet" />
</head>
<body>
	<div id="js-console"></div>
	<script src="scripts/js-console.js"></script>
	<script>
		function hasProperty(obj, property) 
		{
		    for (var i in obj) 
			{
		        if (i == property) 
				{
		            return true;
		        }
		    }
		    return false;
		}

		var test = {obj1: 1, obj2: 2, obj3: 3, obj4: 4, obj5: 5, obj6: 6,};
		jsConsole.writeLine("The test contents the properties: ");
		for(var i in test)
		{
			jsConsole.writeLine(i);
		};

		var hasPropertyOf = hasProperty(test, "test7");
		jsConsole.writeLine("The test object contains property obj7 is: "+hasPropertyOf);
	</script>
</body>
</html>
